package com.aiti.lulian.controller.xlb;

import com.aiti.base.core.base.controller.WebController;
import com.aiti.base.core.utils.message.Message;
import com.aiti.lulian.dto.xlb.XlbEnterpriseDto;
import com.aiti.lulian.service.IXlbEnterpriseService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Api(tags = "小蓝本控制层")
@RestController
@RequestMapping("/xlb")
public class XlbController extends WebController {

    @Autowired
    private IXlbEnterpriseService xlbEnterpriseService;

    @ApiOperation("保存或更新小蓝本企业数据")
    @PostMapping("/enterprise/saveOrUpdate")
    public Message saveOrUpdate(@RequestBody XlbEnterpriseDto dto) {
        xlbEnterpriseService.saveOrUpdate(dto);
        return Message.success();
    }
}
